# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: csslayer <wengxt AT gmail com>

pkgname=fcitx5-libthai
pkgver=5.0.11
pkgrel=1
pkgdesc="Libthai Wrapper for Fcitx5"
arch=('loong64' 'x86_64')
url="https://github.com/fcitx/fcitx5-libthai"
license=('GPL')
depends=('fcitx5' 'libthai')
makedepends=('extra-cmake-modules' 'ninja')
source=("https://download.fcitx-im.org/fcitx5/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig})
sha512sums=('4fff2536d95db0519c235617c7ed1f19e61f6a82d2879edc1ae7a0042e6d3ce1051e3a40e4b53e1f14b1ba73aa7e4ec54ea2d2e7e2bff635eb97d3a7c36477ba'
            'SKIP')
validpgpkeys=('2CC8A0609AD2A479C65B6D5C8E8B898CBF2412F9') # Weng Xuetian <wengxt@gmail.com>

build(){
  cd $pkgname-$pkgver

  cmake -GNinja -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIBDIR=/usr/lib .
  ninja
}

package() {
  cd $pkgname-$pkgver
  DESTDIR="$pkgdir" ninja install
}
